import React, { Component } from 'react';
import { Router, Route, Switch, BrowserRouter } from 'react-router-dom';


import App from './pages/App';
import Login from './pages/Login';
import Home from './pages/Home';
import NoMatch from './pages/404';

class MainRoute extends Component {
    render() {
        return (
            <BrowserRouter>
                <div>
                    <Switch>
                        <Route exact path="/" component={Home} />
                        <Route path="/app" component={App} />
                        <Route path="/login" component={Login} />
                        <Route component={NoMatch} />
                    </Switch>
                </div>
            </BrowserRouter>
        );
    }
}

export default MainRoute;